Skip to content

kboot: Prevent NULL pointer dereference in dt_set_display()#434

Merged
marcan merged 1 commit intoAsahiLinux:mainfrom
jannau:kboot_t602x_dcp_vram
Feb 1, 2025
Merged

kboot: Prevent NULL pointer dereference in dt_set_display()#434
marcan merged 1 commit intoAsahiLinux:mainfrom
jannau:kboot_t602x_dcp_vram

Conversation

@jannau
Copy link
Member

@jannau jannau commented Jan 31, 2025

dt_set_display() relied on display_get_config() returning the default config entry as it is only interested on the device tree alias for the primary dcp. This is always "dcp" except for devices with a config. Since commit 8508526 ("display: contain all display init logic within display.c") it however returns NULL if ADT dcp node specified in the config does not exists. This is the case for M2 Pro and Max macbooks which use "dcp0" instead of "dcp".

Fixes: 8508526 ("display: contain all display init logic within display.c")

dt_set_display() relied on display_get_config() returning the default
config entry as it is only interested on the device tree alias for the
primary dcp. This is always "dcp" except for devices with a config.
Since commit 8508526 ("display: contain all display init logic within
display.c") it however returns NULL if ADT dcp node specified in the
config does not exists. This is the case for M2 Pro and Max macbooks
which use "dcp0" instead of "dcp".

Fixes: 8508526 ("display: contain all display init logic within display.c")
Signed-off-by: Janne Grunau <j@jannau.net>
@marcan marcan merged commit a300ecc into AsahiLinux:main Feb 1, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants